<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en" >
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<style type="text/css">
div#canvas {position:absolute; top:50%; left:50%;}
body {background-color: white;}
</style>
    
        <meta charset="utf-8">
        <title>Pie Menu</title>
        <script src="raphael.js" type="text/javascript"></script>
        <script src="piemenu.js" type="text/javascript"></script>
        <script src="http://ajax.microsoft.com/ajax/jquery/jquery-1.4.4.min.js" type="text/javascript"></script>
        
  
        <script type="text/javascript"> 
        $(document).ready(function() {
            
            
            pieMenu("canvas");
            
            
            //$.getJSON("http://zbigniewolio.appspot.com/proverb?callback=?", function(data){
            //    $("#info").hide();
            //    $("#info").html(data.proverb);
            //    $("#info").fadeIn("slow");
            //});
            
            info = $("#info");
            
            var i = 0;
            var tran = "aunt";
            var org = "ciotka";
            info.html(org);
            var tmp = info.html();
            var len = Math.max(tran.length,tmp.length);
            
            info.click(translate);

            function translate()
            {
                
                var s = info.html().split("");
            //alert(len);    
                if(i >= len)
                    return;
                if(i >= tran.length)
                {
                    info.html(s.join("").substr(0,tran.length));
                    return;
                }
                else   
                    s[i] = tran[i];
                
                i++;
                info.html(s.join(""));
                
                setTimeout(translate,70);
            };
            
        });
        </script>
        
</head>
<body>
        <div id="canvas"></div>
        <cite id="info"></cite>
</body>
</html>